﻿@model IEnumerable<PhotoAlbums.Models.CatalogPhoto>

@{
    ViewBag.Title = "Index";
}

<h2>我的照片</h2>

<p>
    <a href="/Photo/Add?catalogId=@ViewBag.CatalogId">上传照片</a>
</p>

<div class="container-fluid">
    <div class="row">
        @foreach (var item in Model)
        {
            <div class="col-lg-4 col-sm-6 col-xs-12">
                <h3>@Html.DisplayFor(modelItem => item.Photo.Name)</h3>
                <p>@Html.DisplayFor(modelItem => item.Photo.CreateTime)</p>
                <img src="@item.Photo.PhotoPath" class="pa-img img-responsive" />
                <p>
                    <a href="/Comment/Index?photoId=@item.Photo.Id">进入</a> |
                    @Html.ActionLink("修改", "Edit", new { id = item.Photo.Id }) |
                    @Html.ActionLink("删除", "Delete", new { id = item.Photo.Id })
                </p>
            </div>
        }
    </div>
</div>
